<template>
    <div>
      <el-breadcrumb separator-class="el-icon-arrow-right">
        <el-breadcrumb-item :to="{ path: '/start' }">首页</el-breadcrumb-item>
        <el-breadcrumb-item>排行榜</el-breadcrumb-item>
        <el-breadcrumb-item>用户影响力</el-breadcrumb-item></el-breadcrumb>
    <el-table :data="influence" border style="width: 100%;height:450px;overflow:auto;">
    <el-table-column type="index"></el-table-column>
    <el-table-column label="用户名称" prop="name" width="200">
    </el-table-column>
    <el-table-column label="用户简介" prop="weibo" width="450">
    </el-table-column>
    <el-table-column label="影响力" prop="fans" width="150">
    </el-table-column>
    <el-table-column label="用户地址" width="220" show-overflow-tooltip>
  <template slot-scope="scope">
    <a :href="scope.row.url" target="_blank" class="buttonText">用户主页</a>
  </template>
</el-table-column>
    </el-table></div>
</template>

<script>
import axios from 'axios'
export default {
  name: 'Influence',
  data () {
    return {
      influence:[]

    }
  },
  methods: {
    getInfluence () {
      const path = `http://127.0.0.1:5000/influence`
      axios.get(path)
        .then(response => {
          // alert(response.data.config)
          this.influence = response.data.influence
        })
        .catch(error => {
          console.log(error)
        })
    }
  },

  created () {
    this.getInfluence()
  }
}
</script>

<style>

</style>
